<?php
/*
Template Name: post template
*/
?>

<?php get_header(); ?>

 <div id="page">

  <div id="contentleft">

<?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>

    <h2 class="sectionhead">Monthly Archives</h2>
    <div class="post">
     <ul id="archives"><?php wp_get_archives('type=monthly'); ?></ul>
    </div>

    <h2 class="sectionhead">Category Archives</h2>
    <div class="post">
     <ul id="archives"><?php wp_list_categories('title_li='); ?></ul>
    </div>

    <h2 class="sectionhead">Post-by-Post Archives</h2>
    <div class="post">
     <ul id="archives"><?php wp_get_archives('type=postbypost'); ?></ul>
    </div>

<?php endwhile; endif; ?>

  </div>

<?php get_sidebar(); ?>

 </div>

<?php get_footer(); ?>